feat(deps): migrate to ipx v4 - #2094
Conversation
commit: |
Deploying nuxt-image with
|
| Latest commit: |
b936579
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://28f7de0c.nuxt-image.pages.dev |
| Branch Preview URL: | https://feat-ipx-v4.nuxt-image.pages.dev |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #2094 +/- ##
=======================================
Coverage 32.61% 32.61%
=======================================
Files 7 7
Lines 371 371
Branches 131 131
=======================================
Hits 121 121
Misses 194 194
Partials 56 56 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
📝 WalkthroughWalkthroughThe IPX dependency is upgraded to Estimated code review effort: 3 (Moderate) | ~20 minutes 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
🧹 Nitpick comments (1)
src/runtime/server/routes/_ipx.ts (1)
30-54: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winAdd regression coverage for the H3-to-Fetch translation.
Codecov reports no coverage for this new path. Add tests for the default and a custom
baseURL, including query preservation and successful image response forwarding; this replacesuseBase’s previously tested framework behavior.🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@src/runtime/server/routes/_ipx.ts` around lines 30 - 54, Add regression tests covering the H3 event handler’s Fetch translation through _handler: verify the default and custom baseURL paths are stripped correctly, query parameters are preserved, and a successful image response is forwarded. Replace the prior useBase framework-behavior coverage with these route-specific tests.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Nitpick comments:
In `@src/runtime/server/routes/_ipx.ts`:
- Around line 30-54: Add regression tests covering the H3 event handler’s Fetch
translation through _handler: verify the default and custom baseURL paths are
stripped correctly, query parameters are preserved, and a successful image
response is forwarded. Replace the prior useBase framework-behavior coverage
with these route-specific tests.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 914afa4a-163b-44af-aed0-6c5871076611
⛔ Files ignored due to path filters (1)
pnpm-lock.yamlis excluded by!**/pnpm-lock.yaml
📒 Files selected for processing (2)
package.jsonsrc/runtime/server/routes/_ipx.ts
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@src/runtime/server/routes/_ipx.ts`:
- Line 5: Update the h3 adapter import used by the IPX route to one exported by
the installed h3 version, replacing fromNodeHandler with fromNodeMiddleware if
its NodeHttpHandler signature is compatible. Keep lazyEventHandler behavior
unchanged and verify the surrounding handler invocation remains type-safe.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro Plus
Run ID: 6d6cc2db-ced9-43f4-aee1-fc7650d6e643
⛔ Files ignored due to path filters (1)
pnpm-lock.yamlis excluded by!**/pnpm-lock.yaml
📒 Files selected for processing (4)
package.jsonpnpm-workspace.yamlsrc/runtime/providers/ipx.tssrc/runtime/server/routes/_ipx.ts
🚧 Files skipped from review as they are similar to previous changes (1)
- package.json
|
This PR resolves #2181 |
|
All alerts resolved. Learn more about Socket for GitHub. This PR previously contained dependency changes with security issues that have been resolved, removed, or ignored. |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@src/runtime/server/routes/_ipx.ts`:
- Around line 30-39: Update the baseURL handling in the createIPXNodeHandler
parseURL callback: normalize opts.baseURL by removing its trailing slash before
matching, then strip it only when pathname equals the normalized mount or starts
with the mount followed by '/'. Preserve '/' when the stripped pathname is
empty, and use the normalized value when reconstructing the URL for parseIPXURL.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro Plus
Run ID: 86f3fb76-e494-4b80-9112-21c3757422d1
⛔ Files ignored due to path filters (1)
pnpm-lock.yamlis excluded by!**/pnpm-lock.yaml
📒 Files selected for processing (4)
package.jsonpnpm-workspace.yamlsrc/runtime/providers/ipx.tssrc/runtime/server/routes/_ipx.ts
🚧 Files skipped from review as they are similar to previous changes (3)
- pnpm-workspace.yaml
- src/runtime/providers/ipx.ts
- package.json
🔗 Linked issue
resolves #2063
resolves #1425
resolves #1697
closes #2181
❓ Type of change
📚 Description
this migrates us to ipx v4 🎉